<template>
  <el-form size="mini">
    <el-form-item label="当前用户信息">
    </el-form-item>
    <el-form-item label="用户名">
      <el-input v-model="userinfo.ssn" :readonly="true"></el-input>
    </el-form-item>

    <el-form-item label="账号">
      <el-input v-model="userinfo.username" :readonly="true" ></el-input>
    </el-form-item>

    <el-form-item label="手机号">
      <el-input v-model="userinfo.phoneNum" :readonly="true" ></el-input>
    </el-form-item>

    <el-form-item label="组织">
      <el-input v-model="userinfo.orgName" readonly="readonly" :readonly="true"></el-input>
    </el-form-item>

    <el-form-item label="角色">
      <el-input v-model="userinfo.roleName" readonly="readonly" :readonly="true"></el-input>
    </el-form-item>
  </el-form>
</template>

<script>
  import { token } from '../../../../build/config'
  import { getToken } from '../../../utils/auth'
  import FileItem from '../../../components/File/FileItem'
  import MarkdownView from '../../../components/File/FileView/MarkdownView'

  export default {
    name: 'ProfileInfo',
    components: { MarkdownView, FileItem },
    data: function() {
      return {
        imgData: null,
        fileinfo: {
          fileName: "12333333333333333333",
          tags: [
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
            {
              tagName: "java"
            },
          ]
        }
      }
    },
    props: {
      userinfo: {
        ssn: null,
        username: null,
        phoneNum: null,
        orgName: null,
        roleName: null,
      }
    },
    created() {
      // this.$api.getImageData("1236543722627973121").then(res =>{
      //   console.log(res.headers['content-type'].replace(";charset=UTF-8", ""))
      //   return `data:${res.headers['content-type'].replace(";charset=utf-8", "")};base64,` + btoa(
      //     new Uint8Array(res.data)
      //       .reduce((data, byte) => data + String.fromCharCode(byte), '')
      //   );
      // }).then (data => {
      //   this.imgData = data
      // })
    },
    mounted() {

    },
    methods: {

    }
  }
</script>

<style scoped>

</style>
